+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
+2001-01-10 Havoc Pennington <hp@redhat.com>
+
+ * gtk/gtktreeviewcolumn.c (gtk_tree_view_column_clear_attributes):
+ add this function, bug 40251
+
+ * gtk/gtktreemodelsimple.h (GTK_TYPE_TREE_MODEL_SIMPLE): fix name
+ of type macro
+
2001-01-11 Alexander Larsson <alexl@redhat.com>
* acconfig.h:
#endif /* __cplusplus */
-#define GTK_TYPE_MODEL_SIMPLE (gtk_tree_model_simple_get_type ())
+#define GTK_TYPE_TREE_MODEL_SIMPLE (gtk_tree_model_simple_get_type ())
#define GTK_TREE_MODEL_SIMPLE(obj) (GTK_CHECK_CAST ((obj), GTK_TYPE_MODEL_SIMPLE, GtkTreeModelSimple))
#define GTK_TREE_MODEL_SIMPLE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GTK_TYPE_MODEL_SIMPLE, GtkTreeModelSimpleClass))
#define GTK_IS_TREE_MODEL_SIMPLE(obj) (GTK_CHECK_TYPE ((obj), GTK_TYPE_MODEL_SIMPLE))
gtk_tree_view_column_set_attributesv (GtkTreeViewColumn *tree_column,
va_list args)
{
- GSList *list;
gchar *attribute;
gint column;
attribute = va_arg (args, gchar *);
- list = tree_column->attributes;
-
- while (list && list->next)
- {
- g_free (list->data);
- list = list->next->next;
- }
- g_slist_free (tree_column->attributes);
- tree_column->attributes = NULL;
-
+ gtk_tree_view_column_clear_attributes (tree_column);
+
while (attribute != NULL)
{
column = va_arg (args, gint);
va_end (args);
}
+/**
+ * gtk_tree_view_column_clear_attributes:
+ * @tree_column: a #GtkTreeViewColumn
+ *
+ * Clears all existing attributes previously set with
+ * gtk_tree_view_column_set_attributes().
+ **/
+void
+gtk_tree_view_column_clear_attributes (GtkTreeViewColumn *tree_column)
+{
+ GSList *list;
+
+ g_return_if_fail (GTK_IS_TREE_VIEW_COLUMN (tree_column));
+
+ list = tree_column->attributes;
+
+ while (list && list->next)
+ {
+ g_free (list->data);
+ list = list->next->next;
+ }
+ g_slist_free (tree_column->attributes);
+ tree_column->attributes = NULL;
+}
+
/**
* gtk_tree_view_column_set_cell_data:
* @tree_column: A #GtkTreeViewColumn.
gint column);
void gtk_tree_view_column_set_attributes (GtkTreeViewColumn *tree_column,
...);
+void gtk_tree_view_column_clear_attributes (GtkTreeViewColumn *tree_column);
void gtk_tree_view_column_set_cell_data (GtkTreeViewColumn *tree_column,
GtkTreeModel *tree_model,
GtkTreeIter *iter);